<%@ taglib uri="/tags/struts-bean" prefix="bean" %>
<%@ taglib uri="/tags/struts-html" prefix="html" %>
<%@ taglib uri="/tags/core" prefix="c"%>
<script>
			$(document).ready(function(){
				$(".ajax").colorbox({scrolling:false, title:false, top:150});
			});
			
</script>		
<div style="padding-top:20px;">
	<table align="center" width="410" border="0" cellspacing="0" cellpadding="0">
		<tr>
			<td class="titulosPL" align="center" colspan="9"><img src="img/almacen.gif" alt="Planta" width="22" align="absmiddle"><c:out value="${WarehouseForm.warehouseView.code}"/> - <c:out value="${WarehouseForm.warehouseView.name}"/></td>
		</tr>
		<c:forEach var="stockView" items="${WarehouseForm.warehouseView.stockViews}">
			<tr>
				<td align="center" class="etiqueta"><c:out value="${stockView.sapAmount}"/></td>
				<td>&nbsp;</td>
				<td align="center" title="<c:out value="${stockView.cornTypeView.description}"/>">
					<a class="ajax" href="goInventoryByUbication.do?cornTypeId=<c:out value="${stockView.cornTypeView.cornTypeId}"/>"><c:out value="${stockView.cornTypeView.shortName}"/></a>
				</td>
				<td>&nbsp;</td>
				<td class="marco"><img src="img/verde.gif" width="<c:out value="${ (stockView.percentage/100)*32 }"/>" height="11"></td>
				<td>&nbsp;</td>
				<td><c:out value="${stockView.percentage}"/>%</td>
				<td>&nbsp;</td>
				<td align="right"><c:out value="${stockView.cimaAmount}"/> ton</td>
			</tr>
		</c:forEach>
		<tr> 
			<td colspan="8">&nbsp;</td>
			<td class="resultado" align="right"><c:out value="${WarehouseForm.warehouseView.totalStock}"/> ton</td>
		</tr>
		<tr> 
			<td colspan="9" class="rayado">&nbsp;</td>
		</tr>
		<c:forEach var="unitView" items="${WarehouseForm.unitTransitView.unitViews}">
			<tr> 
	            <td width="170" align="right" class="etiqueta"><font size="1"><b>T</b>&nbsp;<c:out value="${unitView.route}"/> - <c:out value="${unitView.date}"/> - <c:out value="${unitView.hoppers}"/></font></td>
	            <td width="10">&nbsp;</td>
	            <td width="60" colspan="3" align="center"><c:out value="${unitView.cornType}"/></td>
	            <td width="10">&nbsp;</td>
	            <td width="60" align="center"><img src="img/<c:out value="${unitView.transportType}"/>" width="39"></td>
	            <td width="10">&nbsp;</td>
	            <td width="90" align="right"><c:out value="${unitView.amount}"/> ton</td>
          	</tr>
		</c:forEach>
		<tr> 
			<td colspan="8">&nbsp;</td>
			<td class="resultado" align="right"><c:out value="${WarehouseForm.unitTransitView.totalTransit}"/> ton</td>
		</tr>
		<tr> 
			<td colspan="9" class="rayado">&nbsp;</td>
		</tr>
		<tr>
			<td colspan="9">
				<ul class="horizontal-list">
					<li class="element-float">
						<html:link action="/entries" styleClass="botonNormal content"><bean:message key="welcome.movements"/></html:link>
					</li>
					<li>
					<html:link action="/getReports" styleClass="botonNormal content"><bean:message key="welcome.reports"/></html:link>
					</li>
				</ul>
			</td>
		</tr>
		<tr> 
			<td colspan="9" class="rayado">&nbsp;</td>
		</tr>
	</table>
</div>